// -----------------------------
// Author: 		Dhaenens Gert 
// Creation: 	9/24/2014 3:09:29 PM				
// -----------------------------

#ifndef _LuaVariable_h
#define _LuaVariable_h

#include "ObjectLuaCommon.h"
#include "LuaRef.h"

namespace ObjectLua
{

	class LuaScript;

	class OBJECTLUA LuaVariable
	{
	public:
		LuaVariable(Lua* lpLua, LuaScript* lpScript, const char* Name, LuaRef ref);
		LuaVariable(const LuaVariable& refLuaVariable);
		LuaVariable& operator=(const LuaVariable& refLuaVariable);
		~LuaVariable();

		template<typename T>
		T			get() const;
	
	private:

		Lua*		m_lpLua;
		LuaRef		m_Ref;
		LuaScript*	m_lpScript;
		char*		m_Name;
	};

}

#include "LuaVariable.inl"
#endif